using UnityEngine;

public class Player : MonoBehaviour
{
    void Start()
    {
        Destroy(gameObject, 10f);
        ListenerMgr.GetInstance().AddTrigger<Monster>("MonsterDead", MonsterDead);
    }

    private void OnDestroy()
    {
        Debug.LogFormat("[Player][OnDestroy]...");
        ListenerMgr.GetInstance().RemoveTrigger<Monster>("MonsterDead", MonsterDead);
    }

    public void MonsterDead(object obj)
    {
        Debug.LogFormat("[Player][MonsterDead] name:{0}", (obj as string));
    }
}
